Skip to content

docs: use node-redis in the Redis quick start example#3306

Merged
bartlomieju merged 1 commit into
mainfrom
docs-redis-quickstart-node-redis
Jun 18, 2026
Merged

docs: use node-redis in the Redis quick start example#3306
bartlomieju merged 1 commit into
mainfrom
docs-redis-quickstart-node-redis

Conversation

@bartlomieju

Copy link
Copy Markdown
Member

Rewrites the Redis quick start example (examples/scripts/redis.ts) to use
the popular npm:redis client (node-redis) instead of jsr:@iuioiua/redis.

This makes the quick start consistent with the companion caching tutorial,
which already uses node-redis, and addresses the confusion reported in #1676:

  • The connection now uses createClient with an explicit socket.host and
    port, so it's clear where a remote host goes (the original only showed a
    port).
  • Reading and writing use the high-level set/get methods rather than raw
    sendCommand, which is what tripped up the reporter.
  • A sendCommand example remains for commands without a dedicated method
    (such as RedisJSON's JSON.SET), showing each argument as a separate array
    element.

Type-checks against node-redis 4.7.1 and passes deno fmt.

Closes #1676

@bartlomieju
bartlomieju merged commit 7d16359 into main Jun 18, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Improve redis example

1 participant